<div class="form-group clearfix">
  <div class="form-inline pull-left">
    <button type="button" class="btn btn-default" routerLink="../add-config">新增配置</button>
  </div>
</div>

<div *ngIf="configList">
  <table class="table">
    <thead>
      <tr>
        <th>编号ID</th>
        <th>公司名称</th>
        <th>站点名称</th>
        <th>使用状态</th>
        <th>操作</th>
      </tr>
    </thead>
    <tbody>
      <tr *ngFor="let item of configList.data">
        <td>{{item.id}}</td>
        <td>{{item.company_name}}</td>
        <td>{{item.site_name}}</td>
        <td>{{item.is_use}}</td>
        <td>
          <a href="javascript:;" routerLink="../config-detail/{{item.id}}">详细</a>-
          <a href="javascript:;" routerLink="../config-edit/{{item.id}}">编辑</a>-
          <a href="javascript:;" (click)="delSite(item.id)">删除</a>
        </td>
      </tr>
    </tbody>
  </table>

  <!--<div class="text-center">-->
    <!--<pagination (pageChanged)="pageChanged($event)" [totalItems]="configList.total" [itemsPerPage]="configList.per_page" [(ngModel)]="configList.current_page"-->
                <!--previousText="&lsaquo;" nextText="&rsaquo;" firstText="&laquo;" lastText="&raquo;" [boundaryLinks]="true" class="pagination-sm"></pagination>-->
  <!--</div>-->
</div>

<!-- 是否确认删除弹框 -->
<div class="modal fade" bsModal #delModal="bs-modal" tabindex="-1">
  <div class="modal-dialog">
    <div class="modal-content">
      <div class="modal-header">
        <h4 class="modal-title pull-left">提示</h4>
        <button type="button" class="close pull-right" aria-label="Close" (click)="delModal.hide()">
          <span aria-hidden="true">&times;</span>
        </button>
      </div>
      <div class="modal-body text-center">
        是否确认删除
      </div>
      <div class="modal-footer mt20">
        <button class="btn btn-default btn-md-long" type="button" (click)="delModal.hide()">取消</button>
        <button class="btn btn-success btn-md-long" type="submit" (click)="delSiteSubmit()">确定</button>
      </div>
    </div>
  </div>
</div>

<app-notification [type]="type" [message]="message" [isShow]="isShow" (promptIsShow)="isShow = $event"></app-notification>
